package team.lourd.network.system.own.domain.pretrem;

import lombok.Getter;
import lombok.Setter;
import team.lourd.network.system.own.domain.Detail;
import team.lourd.network.system.own.domain.Operation;

import javax.persistence.*;
import java.util.List;

/**
 * @Description: 用于记录预处理模型的内容信息
 * @Author: Lourd
 * @Date: 2019/1/21
 */
@Table(name = "pm_work")
@Entity
@Getter
@Setter
public class PMWork extends Detail {

    @Enumerated(EnumType.ORDINAL)
    private PMType type=PMType.OTHER;

    private String target;

    private String description;

    // private String pMWynlId;
    private String command;

    @OneToOne(cascade = CascadeType.ALL)
    private PMModel pmModel;

    @OneToMany(mappedBy = "pmWork", cascade = CascadeType.ALL)
    private List<Operation> operations;

}
